import http from '@/api/http'

// 修改阅读消息状态
export const updatamessagemay=(data)=>{
    return http({
        url: "updatamessagemay",
        method: "post",
        data  
    })
}

// 退出登陆
export const LoginOut = (_id) => {
    return http({
        url: "loginout",
        method: "get",
        params:{
            _id
        }  
    })
}


// 登陆
export const postLogin = (data) => {
    return http({
        url: "login",
        method: "get",
        params:data
    })
}

// 登陆后，获取所有用户信息
export const getUserlist = () => {
    return  http({
        url: "userlist",
        method: "get",    
    })
}



//获取卖座的首页推荐数据
export const getPosiData = () => {
    return http({
        url: "gateway?cityId=510100&pageNum=1&pageSize=10&type=1&k=7030830",
        method: "get",
        headers: {
            "X-Host": "mall.film-ticket.film.list",
        }
    })
}

//获取卖座的电影详情数据
export const getVideo = (Id) => {
    return http({
        url: `gateway?filmId=5245&k=5192786`,
        method: "get",
        headers: {
            "X-Host": "mall.film-ticket.film.info",
        }
    })
}

//获取卖座的电影上映地区的具体电影院数据
export const getHomeList = (username) => {
    return http({
        url: "gateway?k=1076685",
        method: "post",
        headers:{
            'X-Host': 'mall.film-ticket.cinema.batch-cinema'
        },
        params: {      //url直接的后接请求参数
            id: 12
        },
        data: //请求体，不在url中
            { "cityId": 510100, "cinemaIds": "9665,9152,8972,2450,5332,8531,9238,9265,4747,9680,10327,1047,5064,5912,8457,8965,9018,1044,2480,2481,3973,7663,10303,739,1896,4786,4820,7513,8993,9158,9426,9704,9870,9872,10263,10362,367,1048,1055,1857,3178,6389,6606,7646,7985,8771,8974,8998,8999,9056,9754,150,730,1498,1918,1979,2888,4787,4896,5062,8529,9019,9048,9070,9436,9807,9919,10120,10180,10198,1038,1040,1042,2894,4722,4732,4742,6726,7401,7904,7918,7924,8975,8995,9037,9051,9153,9338,9546,9818,10164,10183,1024,1041,2886,4738,5068,5078,6041,7655,7903,8996,9066,9071,9160,9990,1004,1036,1049,1322,1897,2432,2479,2853,4741,4746,7907,7980,7982,7986,8833,9069,9547,9687,9758,10189,10202,10401,1039,1043,2095,2452,3799,7444,9065,9068,9102,9703,9753,10109,296,1025,2306,2887,4890,5061,8976,9049,9050,4736,4779,4785,9075,9759,10363,1019,4762,4780,9266,9435,9573,9880,9882,10309,4783,10308" }
    }

    )
}

